package com.aysafety.iotdataplatformweb.services.electromagnetic;

import java.util.List;
import java.util.Map;

public interface ElectromagneticService {
    long countByElectromagneticIntensity(String mineId, String deviceId, String startTime, String endTime, int timeSpan,
        String timeUnit) throws Throwable;

    List<Map<String, Object>> queryRealTimeByElectromagneticIntensity(String mineId, String deviceId, String startTime,
        String endTime, int timeSpan, String timeUnit, int page, int size, String startRow) throws Throwable;

    long countByElectromagneticPulse(String mineId, String deviceId, String startTime, String endTime, int timeSpan,
        String timeUnit) throws Throwable;

    List<Map<String, Object>> queryRealTimeByElectromagneticPulse(String mineId, String deviceId, String startTime,
        String endTime, int timeSpan, String timeUnit, int page, int size, String startRow) throws Throwable;

    /**
     * @Description:  web调用接口-电磁辐射趋势预警指标A数量
     * @Param: [mineId, workingFace, startTime, endTime, m, dt]
     * @return: long
     * @Author: ChengQi
     * @Date: 2018/12/20
     */
    long countWebElectromagneticRadiationWarning(String mineId, String workingFace, String startTime, String endTime, int m, int dt) throws Throwable;

    /**
     * @Description:  web调用接口-电磁辐射趋势预警指标A数据
     * @Param: [mineId, workingFace, startTime, endTime, m, dt, page, size, startRow]
     * @return: java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
     * @Author: ChengQi
     * @Date: 2018/12/20
     */
    List<Map<String, Object>> queryCal(String mineId, String workingFace, String startTime, String endTime, int n,int m, int dt,int a) throws Throwable;

    /**
     * @Description:  web调用接口-n小时偏差值
     * @Param: [mineId, workingFace, startTime, endTime, m, dt]
     * @return: long
     * @Author: ChengQi
     * @Date: 2018/12/20
     */
    long countWebDeviation(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n) throws Throwable;

    /**
     * @Description:  web调用接口-n小时偏差值数据
     * @Param: [mineId 矿区id, workingFace, startTime, endTime, m, dt, page, size, startRow]
     * @return: java.util.List<java.util.Map<java.lang.String,java.lang.Object>>
     * @Author: ChengQi
     * @Date: 2018/12/20
     */
    List<Map<String, Object>> queryWebDeviation(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n) throws Throwable;

    /** 
    * @Description:  web调用接口-偏离异常持续时间h
    * @Param: [mineId, workingFace, startTime, endTime, m, dt, n] 
    * @return: long 
    * @Author: ChengQi 
    * @Date: 2018/12/25 
    */ 
    long deviationLast(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n);

    /** 
    * @Description:web调用接口-偏离异常持续时间h
    * @Param: [mineId, workingFace, startTime, endTime, m, dt, n] 
    * @return: java.util.List<java.util.Map<java.lang.String,java.lang.Object>> 
    * @Author: ChengQi 
    * @Date: 2018/12/25 
    */ 
    List<Map<String, Object>> querydeviationLast(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n,double a) throws Throwable;

    /** 
    * @Description:  web调用接口-累计偏离异常持续时间h
    * @Param: [mineId, workingFace, startTime, endTime, m, dt, n, a] 
    * @return: java.util.List<java.util.Map<java.lang.String,java.lang.Object>> 
    * @Author: ChengQi 
    * @Date: 2018/12/25 
    */ 
    List<Map<String, Object>> deviationLastTotal(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n, double a) throws Throwable;

    /** 
    * @Description:  web调用接口- n小时偏离异常频次N
    * @Param: [mineId, workingFace, startTime, endTime, m, dt, n] 
    * @return: java.util.List<java.util.Map<java.lang.String,java.lang.Object>> 
    * @Author: ChengQi 
    * @Date: 2018/12/25 
    */ 
    List<Map<String, Object>> deviationFrequency(String mineId, String workingFace, String startTime, String endTime, int m, int dt, int n,double a) throws Throwable;

    /** 
    * @Description: 综合预警
    * @Param: [mineId, startTime, endTime] 
    * @return: java.util.Map<java.lang.String,java.lang.Object> 
    * @Author: ChengQi 
    * @Date: 2019/1/9 
    */ 
    Map<String, Object> comprehensiveWarning(String mineId, String startTime, String endTime) throws Throwable;
}
